package com.enation.app.javashop.core.client.fallback.member;

import com.enation.app.javashop.core.client.feignimpl.member.MemberCollectionShopClientFeignImpl;
import com.enation.app.javashop.core.handler.BaseFallbackFactory;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;

/**
 * 会员店铺收藏相关熔断fallback factory
 * @author kingapex
 * @version 1.0
 * @data 2022/5/28 14:25
 **/
@Component
public class MemberCollectionShopFallbackFactory extends BaseFallbackFactory< MemberCollectionShopClientFeignImpl> {
    @Override
    protected MemberCollectionShopClientFeignImpl fallback() {
        return new MemberCollectionShopFallback();
    }

    /**
     * 会员店铺收藏相关熔断
     *
     * @author zh
     * @version v7.0
     * @date 18/9/27 下午3:58
     * @since v7.0
     */
    @Component
    public static class MemberCollectionShopFallback implements MemberCollectionShopClientFeignImpl {

        private final Logger logger = LoggerFactory.getLogger(getClass());


        @Override
        public void changeSellerName(Long sellerId, String sellerName) {
            logger.error("修改店铺名称出错");
        }
    }
}
